Route to Autopilot

Send a Route to the Autopilot, the basics

If an autopilot is connected to an output port, as defined in the Options→Connections tab, and a route is active, OpenCPN sends NMEA RMB, RMC, and APB sentences to the A/P.

Read more in Options > Connections Sending an Active Route to an Autopilot[2069]
in Options > Data Connections (at the bottom) for more information about connections and testing.

Note that a Connections Output Port must be configured to send ECRMB, ECRMC and ECAPB NMEA sentences to the Auto Pilot.

Also read about the Activate Route & Active Route [2070] Console[2071] and Active Route Console Window - Showing Active Leg [2072] Data[2073]in Marks and Routes towards the bottom.

It is essential to have turned on an Active Route in order to send waypoints to the Autopilot.

Waypoint Advance

OpenCPN automatically shifts to the next waypoint in the route using an arrival radius of 0.05 miles (= 92.6 m) by default. This value can be changed in Options→Ships→Own Ship. The arrival radius can be adjusted in each waypoint properties dialog as well.

This works fine in the general case. The A/P is watching the NMEA stream. It sees a new destination lat/lon, and new heading to steer, and then asks the user for confirmation to make the turn. Raytheon/Autohelm works this way.

Simulation & Testing - Short description

To create outgoing ECxxx messages make a (left click menu) “Navigate to here” to a arbitrary point. You may need to filter outgoing sentences on the network connection to only send “EC” (and filter out the same on the incoming side to avoid feedback) so you don't receive them and then send duplicates. The information is scattered so use your browser to search for “autopilot”.

Autopilots and Routes, the details.

Please read Advance route waypoint on arrival [2074] only[2075]first. Here is a detailed discussion of Options→Ships→OwnShip→Advance route waypoint on arrival only. With an Active Route, in the Active Route Console “This Leg” is visible near the upper right corner of the screen in the console:

../Images/opencpn_manual_4rng.png

RNG (actual range) Distance to the next waypoint.
NR (normal range) Distance from destination waypoint to a line orthagonal (right angles) to the current route segment which passes through ownship. When shown in the Console window, NR is after RNG.

../Images/opencpn_manual_diagram-0-sm.png

There are two general conditions:
1.RNG=NR On course with no cross track error (XTE=0)
2. RNG>NR Off course (sailing perhaps) with cross track error (XTE>0)
When the difference is greater than 10% both values are shown in “RNG”

../Images/opencpn_manual_4rng.png

The “normal” range is the second number shown. 1.88 in this case.

Four Different Conditions

Waypoint Advance is the normal default OR Advance Waypoint upon Arrival only when selected in Options.

The four diagrams below represent four different conditions:

  1. Waypoint AdvanceRNG = NR and XTE=0 (Boat is on the route)
  2. Waypoint Advance RNG > NR and XTE>0 (Boat is off the route), console shows both RNG and NR and NR x 1.1 > RNG.
  3. Advance Waypoint on Arrival only when when RNG=NR and XTE=0 and NR<Arrival Radius
  4. Advance Waypoint on Arrival only when RNG >1.1 x NR and XTE>0

1. Waypoint Advance when RNG=NR and XTE=0 (or near 0)

Under Waypoint Advance mode (the normal default) when

when following a Route OpenCPN normally decides to advance to the next waypoint if at least one of the following two conditions apply.

../Images/opencpn_manual_diagram-1-sm.png

2. Waypoint Advance when RNG 10%>NR and XTE>0

Under Waypoint Advance mode (the normal default) when

when following a Route OpenCPN normally decides to advance to the next waypoint if at least one of the following two conditions apply.

../Images/opencpn_manual_diagram-2-sm.png

3. Advance Waypoint on Arrival Only when RNG=NR and XTE=0

With Advance Route Waypoint on arrival only checked and activated, when

when following a Route, OpenCPN only advances the route to the next waypoint when

../Images/opencpn_manual_diagram-3-sm.png

4. Advance Waypoint on Arrival Only when RNG >1.1 x NR and XTE>0

With Advance Route Waypoint on arrival only checked and activated, when

when following a Route, OpenCPN only advances the route to the next waypoint when

[Editor's Diagram Correction: Boat B location Normal Range should be shown at the arrival radus with boat starting the turn!]

../Images/opencpn_manual_diagram-4-sm.png

When to use Advance Waypoint upon Arrival only

Advance Waypoint upon arrival only (option) is useful when sailing and you can't lay the next mark and are forced to tack to reach it. It allows a ship to move away from waypoint without automatically advancing to next waypoint.
Note: Waypoint Advance (normal default) is dependent on NR < Arrival Radius OR RNG increasing more than 2 seconds, so what this option does is overide that second condition.

Advance Waypoint upon arrival only (option) ensures that the current waypoint remains active
1. NR<Arrival Radius is reached OR
2. A line just inside of the Arrival Radius which is also “normal” or perpendicular to the marked route is reached. In this case there is a cross track error.

On the other hand….
Waypoint Advance (normal defualt) helps you if you really want to cut a corner by a large distance, in such a way that the “normal range” will never be less than (Arrival radius). The second condition, RNG increases for > 2 seconds, willl automatically advance the route to the next waypoint in this case.